package com.richman.ps38;

import com.richman.controller.BetClient;

public class PS38Thread extends Thread {
	
	public long sleepTime = 30*1000;
	PS38Manager ps38Manager = null;
	
	boolean start = false;
	boolean loginNow = false;
	
	boolean bexit = false;
	
	public static long refreshTime = System.currentTimeMillis(); 

	public PS38Thread(){		
	
	}
		
	public boolean getbexit() {
		return bexit;
	}
	
	@Override
    public void run() {

		try{

			while(BetClient.bStartEngine){
				try{
					BetClient.betCtrMng.keepPS38online();
					BetClient.betCtrMng.udpateps38BetLogData();
					
					refreshTime = System.currentTimeMillis();
					
				}catch(Exception e){
					e.printStackTrace();
					Thread.sleep(2000);
				}
				

			}
			
			
			
			//DaShuiClient.mainWnd.updatePS38EventsTable(PS38Manager.ps38Events);
			
			bexit = true;

		}catch(Exception e){
			e.printStackTrace();
		}	
	}
	
}
